<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2021/12/23
  Time: 11:26
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
    <@
    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.js"></script>
    <script>
        var users = new Array();
        users.push({"name":"Lily","sex":"W"})
        users.push({"name":"Lily","sex":"W"})
        $.ajax({
            type:"POST",
            url:"${pageContext.request.contextPath}/user5",
            data:JSON.stringify(users),
            contentType:"application/json;charset = utf-8",
            success:function (data) {
                alert(data)
            },
            error:function (jqXHR,textStatus,errorThrown) {
                alert("error")
            }
        })
    </script>
</head>
<body>

</body>
</html>
